import request from '../utils/httpRequest';
//个人中心
export const orderPage = (pageNo, pageSize, status, refundStatus, commentStatus) => {
    let query = `?pageNo=${pageNo}&pageSize=${pageSize}&refundStatus=${refundStatus}`
    if (status && status != 100) {
        query += '&status=' + status
    }
    if (commentStatus) {
        query += '&commentStatus=' + commentStatus
    }
    return request.get({
        url: `/app-api/trade/order/page${query}`,
    });
};
//订单详情
export const orderDetail = (id, sync) => {
    return request.get({
        url: `/app-api/trade/order/get-detail?id=${id}&sync=${sync}`,
    });
};
//取消订单
export const cancel = (id) => {
    return request.get({
        url: `/app-api/trade/order/cancel?id=${id}`,
    });
};